using System;
using System.Collections.Generic;
using Drawing = System.Drawing;
using System.Text.RegularExpressions;

using Nairo.Parser.Dom;

namespace Nairo.Parser
{
	public struct BoxDistances
	{
		SizeValue left, right, top, bottom;
		
		public BoxDistances(SizeValue left, SizeValue right, SizeValue top, SizeValue bottom)
		{
			this.left = left;
			this.right = right;
			this.top = top;
			this.bottom = bottom;
		}
		
		public BoxDistances(double value, RelativeUnits unit)
		{
			this.left = new SizeValue(value, true, false, false, unit, AbsoluteUnits.None, SpecialSizeValues.None);
			this.right = new SizeValue(value, true, false, false, unit, AbsoluteUnits.None, SpecialSizeValues.None);
			this.top = new SizeValue(value, true, false, false, unit, AbsoluteUnits.None, SpecialSizeValues.None);
			this.bottom = new SizeValue(value, true, false, false, unit, AbsoluteUnits.None, SpecialSizeValues.None);
		}
		
		public SizeValue Left {
			get { return left; }
			set { left = value; }
		}
		
		public SizeValue Right {
			get { return right; }
			set { right = value; }
		}
		
		public SizeValue Top {
			get { return top; }
			set { top = value; }
		}
		
		public SizeValue Bottom {
			get { return bottom; }
			set { bottom = value; }
		}
		
		public override string ToString()
		{
			return string.Format("[BoxDistances Left={0} Right={1} Top={2} Bottom={3}]", this.left, this.right, this.top, this.bottom);
		}
	}
}
